#include <mainwindow.h>
#include <qmenubar.h>
#include <qmenu.h>

cceMainWindow::cceMainWindow(QWidget *parent)
  : QMainWindow(parent)
{
  _sceneEditorSceneView = new cceSceneEditorSceneView (this);

  setCentralWidget(_sceneEditorSceneView);
  InitActions();

}


void cceMainWindow::InitActions()
{
  QMenuBar *mb = menuBar();

  QMenu *menuFile = new QMenu("&File", this);
  _actions[Action_FileExit] = menuFile->addAction("E&xit");
  _actions[Action_FileExit]->setShortcut(QKeySequence(Qt::CTRL + Qt::Key_Q));

  QMenu *menuViews = new QMenu ("&Views", this);
  _actions[Action_ViewMaterialBrowser] = menuViews->addAction("Material browser...");
  _actions[Action_ViewMaterialBrowser]->setShortcut(QKeySequence(Qt::CTRL + Qt::Key_M));
  _actions[Action_ViewObjectBrowser] = menuViews->addAction("Object browser...");
  _actions[Action_ViewObjectBrowser]->setShortcut(QKeySequence(Qt::CTRL + Qt::Key_O));


  mb->addMenu(menuFile);
  mb->addMenu(menuViews);
}


